<script type="text/javascript">
	var caldef1 =
	{
		firstday : 0,
		dtype : 'yyyy-MM-dd',
		width : 250,
		windoww : 300,
		windowh : 200,
		border_width : 0,
		border_color : '#0000d3',
		dn_css : 'clsDayName',
		cd_css : 'clsCurrentDay',
		wd_css : 'clsWorkDay',
		we_css : 'clsWeekEnd',
		wdom_css : 'clsWorkDayOtherMonth',
		weom_css : 'clsWeekEndOtherMonth',
		headerstyle :
		{
			type : "buttons",
			imgnextm : 'img/forward.jpg',
			imgprevm : 'img/back.jpg',
			css : 'clsDayName'
		},
		showtime : true,
		monthnames : ["January", "February", "March", "April", "May", "June",
			"July", "August", "September", "October", "November", "December"],
		daynames : ["Su", "Mo", "Tu", "We", "Th", "Fr", "Sa"],
		template_path : 'http://localhost/GMS/library/javascript/calendar/Builder/',
		img_path : 'http://localhost/GMS/library/javascript/calendar/Builder/img/'

	}; 
	var c3 = new CodeThatCalendar(caldef1); 

</script>


<form id="edit_orders_form" method="POST" action=
		"<{$smarty.const.APPLICATION_URL}>orders/edit/">
	<table border="0" cellpadding="10px">
		<tr>
			<td>
			Receive Date</td>
			<td>
				<input id="ord_receivedate" name="ord_receivedate" size=30 readonly 
			value="<{$current_data.ord_receivedate}>"/>
				<input type="button" onClick="c3.popup('ord_receivedate');" value="..."/>
			</td>
		
		
		<tr>
			<td>Order Receiver</td>
			<td>
				<select id="ord_empreceive_id" name="ord_empreceive_id">
					<{foreach from=$employeesList item=phantu}>
						<option value="<{$phantu.emp_id}>" 
				 		<{if $phantu.emp_id==$current_data.ord_empreceive_id}> 
							selected = "true"
						<{/if}>
						>
							<{$phantu.emp_name}>
						</option>					
					<{/foreach}>
				</select>
			</td>
		</tr>
			
		<td>
			Deliver Date</td>
			<td>
				<input id="ord_issuedate" name="ord_issuedate" size=30 readonly 
			value="<{$current_data.ord_issuedate}>"/>
				<input type="button" onClick="c3.popup('ord_issuedate');" value="..."/>
			</td>
		
		
		<tr>
			<td>Order Deliverer</td>
			<td>
				<select id="ord_empissue_id" name="ord_empissue_id">
					<{foreach from=$employeesList item=phantu}>
						<option value="<{$phantu.emp_id}>" 
				 		<{if $phantu.emp_id==$current_data.ord_empissue_id}> 
							selected = "true"
						<{/if}>
						>
							<{$phantu.emp_name}>
						</option>					
					<{/foreach}>
				</select>
			</td>
		</tr>
		
		<tr>
			<td>Customer</td>
			<td>
				<select id="ord_cus_id" name="ord_cus_id">
					<{foreach from=$customerList item=phantu}>
						<option value="<{$phantu.cus_id}>"
				 		<{if $phantu.cus_id==$current_data.ord_cus_id}> 
							selected = "true"
						<{/if}>
						>
						<{$phantu.cus_firstname}>
						</option>					
					<{/foreach}>
				</select>
			</td>
		</tr>	
		
		
		<tr>
			<td>Payment</td>
			<td>
				<select id="ord_pay_id" name="ord_pay_id">
					<{foreach from=$paymentsList item=phantu}>
						<option value="<{$phantu.pay_id}>"
				 		<{if $phantu.pay_id==$current_data.ord_pay_id}> 
							selected = "true"
						<{/if}>
						>
						<{$phantu.pay_method}>
						</option>					
					<{/foreach}>
				</select>
			</td>
		</tr>	
		
			<td>
				<input id="ord_id" name="ord_id" size=30 
					value="<{$current_data.ord_id}>" style="display:none"/>
			</td>
			
		</tr>
		<tr>
			<td colspan=2 align="left">
				<input type="submit" id="edit_order_btn" 
					name="edit_order_btn" value="Edit"/>
			</td>
		</tr>
	</table>
</form>